//
//  ZXLCollectionViewCell.m
//  EPA
//
//  Created by 朱兴隆 on 16/4/19.
//  Copyright © 2016年 朱兴隆. All rights reserved.
//

#import "ZXLCollectionViewCell.h"

#import "ImageLoading.h"
@interface ZXLCollectionViewCell ()

@property (weak, nonatomic) IBOutlet UIImageView *imageView;
@property (weak, nonatomic) IBOutlet UILabel *titleLabel;

@end

@implementation ZXLCollectionViewCell

- (void)awakeFromNib {
    // Initialization code
}

- (void)setModel:(ZXLHomeModel *)model {
    if (_model != model) {
        _model = model;
    }
}
- (void)layoutSubviews {
    self.titleLabel.text = self.model.name;
    
    [[ImageLoading shareImageLoading] imageLoadingWithString:self.model.coverimg returnImageBlock:^(NSData *data) {
        self.imageView.image = [UIImage imageWithData:data];
    }];
}

@end
